# Maintainer: Luca Weiss <luca@z3ntu.xyz>
pkgname=py3-ytmusicapi
pkgver=1.7.0
pkgrel=0
pkgdesc="Unofficial API for YouTube Music"
url="https://github.com/sigma67/ytmusicapi"
arch="noarch"
license="MIT"
depends="py3-setuptools py3-requests"
makedepends="py3-setuptools_scm py3-gpep517 py3-installer py3-wheel"
subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/y/ytmusicapi/ytmusicapi-$pkgver.tar.gz"
builddir="$srcdir/ytmusicapi-$pkgver"
options="!check" # tests require special auth setup

build() {
	export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/ytmusicapi-$pkgver-*.whl
}

sha512sums="
4e5f021e7dc9879e6cf881595afc8c17637e0d722a019b855563358f38bb74fe5ff154ea639c6d56836967c520bfece504733bf960b77cfe79b0586390339551  ytmusicapi-1.7.0.tar.gz
"
